Problem: Right triangle $ABC$ has one leg of length 6 cm, one leg of length 8 cm and a right angle at $A$. A square has one side on the hypotenuse of triangle $ABC$ and a vertex on each of the two legs of triangle $ABC$. What is the length of one side of the square, in cm? Express your answer as a common fraction.

[asy]
defaultpen(linewidth(0.8));
size(4cm,4cm);

pair A,B,C;

A=(0,0);
B=(2,3);
C=(7,0);

draw(A--B--C--A);

pair a,b,c,d;

a=(2/3)*B+(1/3)*A;
b=(2/3)*B+(1/3)*C;
c=(1.339,0);
d=(3.65,0);

draw(c--a--b--d);

pair x,y,z;

x=(9/10)*B+(1/10)*A;
z=(14/15)*B+(1/15)*C;
y=(2.12,2.5);

draw(x--y--z);

label("$A$",B,N);
label("$B$",A,SW);
label("$C$",C,SE);

[/asy]
Answer: Let $s$ be the side length of the square. Also let $D$ be the vertex of the square on side $AC$, and let $E$ be the vertex of the square on side $AB$. Let $F$ and $G$ be the feet of the altitudes from $D$ and $A$ to $BC$, respectively. Let $x$ be the length of $AD$.

[asy]
unitsize(0.5 cm);

pair A, B, C, D, E, F, G, H, X, Y;

A = (6^2/10,6*8/10);
B = (0,0);
C = (10,0);
G = (6^2/10,0);
X = (0,-10);
Y = (10,-10);
F = extension(A,Y,B,C);
D = extension(F,F + A - G,A,C);
E = extension(D,D + B - C,A,B);
H = E + F - D;

draw(A--B--C--cycle);
draw(H--E--D--F);
draw(A--G);

label("$A$", A, N);
label("$B$", B, SW);
label("$C$", C, SE);
label("$D$", D, NE);
label("$E$", E, NW);
label("$F$", F, S);
label("$G$", G, S);
label("$x$", (A + D)/2, NE);
label("$8 - x$", (D + C)/2, NE);
[/asy]

Without loss of generality, we assume that $AC > AB$, as in the diagram. From the given information, we know that $AC = 8$, $BC = 10$, and $DC = 8-x$. We can find that $AG = AB\cdot AC/BC = 4.8$.

From similar triangles $AED$ and $ABC$, we find that $s/10 = x/8$. From similar triangles $DFC$ and $AGC$, we have $s/4.8 = (8-x)/8$. Summing these two equations, we have $$\frac{s}{10} + \frac{s}{4.8} = \frac{x}{8} + \frac{8-x}{8}$$$$\frac{14.8s}{48} = 1.$$Solving for $s$, we find that $s = \boxed{\frac{120}{37}}$.